<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@include file="../../common/jspcommon.jsp" %>
<script type="text/javascript">
$("#page").pager(
		{
			pagenumber : '${pm.currentPage}',
			pagecount : '${pm.totalPage}',
			buttonClickCallback : function(page) {
				$("#page").hide();
				$("#account_content").load("accountLog.htm",{
					tranType:"${tranType}",
					page:page
				},function(){
					$("#page").show();
				});
			}
		});
		
		function logDetail(){
			$("#account_content").load("accountLog.htm",{
				tranType:"${tranType}",
				startDate:$("#startDate").val(),
				endDate:$("#endDate").val()
			});
			
		}
</script>
<div class="rmbDetail">
	<p class="checkDate">
		起止日期：
		<input type="text" id="startDate"  class="Wdate"  onclick="WdatePicker({autoPickDate:null,highLineWeekDay:true,dateFmt:'yyyy-MM-dd'});"/>&nbsp;-
		<input type="text" id="endDate"  class="Wdate"  onclick="WdatePicker({autoPickDate:null,highLineWeekDay:true,dateFmt:'yyyy-MM-dd'});"/>
		<input type="button" class="checkBtn" value="查询" onclick="logDetail();"/>
	</p>
<c:if test="${not empty pm.list }">
	<table width="700" border="0" cellspacing="1" cellpadding="2">
		<tr>
			<td class="tdColorOne">交易单号</td>
			<td class="tdColorTwo">交易日期</td>
			<td class="tdColorOne">收入金额</td>
			<td class="tdColorTwo">支出金额</td>
			<td class="tdColorOne">余额</td>
			<td class="tdColorTwo">收入/支出账户</td>
			<td class="tdColorOne">交易摘要</td>
		</tr>
		<c:forEach items="${pm.list }" var="al">
			<tr>
				<td>${al.identifier }</td>
				<td><fmt:formatDate value="${al.transactionTime }" pattern="yyyy-MM-dd HH:mm"/></td>
				<td>
					<c:if test="${tranType=='rmb'}">${al.depositRmb }</c:if>
					<c:if test="${tranType=='ggb'}">${al.depositGgb }</c:if>
				</td>
				<td>
					<c:if test="${tranType=='rmb'}">${al.withdrawRmb }</c:if>
					<c:if test="${tranType=='ggb'}">${al.withdrawGgb }</c:if>
				</td>
				<td>
					<c:if test="${tranType=='rmb'}">${al.rmb }</c:if>
					<c:if test="${tranType=='ggb'}">${al.ggb }</c:if>
				</td>
				<td>
					<c:if test="${tranType=='rmb'}">${al.depositRmbAccount }${al.withdrawRmbAccount }</c:if>
					<c:if test="${tranType=='ggb'}">${al.depositGgbAccount }${al.withdrawGgbAccount }</c:if>
				</td>
				<td>${al.summary }</td>
			</tr>
		</c:forEach>
	</table>
</c:if>
	<span>汇率: 1现金=100果果币</span>
	<c:if test="${pm.totalPage>1}">
		<div id="page" class="h_page"></div>
	</c:if>
</div>
